package com.huaxin.device;

import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cache.annotation.EnableCaching;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.EnableAspectJAutoProxy;
import org.springframework.scheduling.annotation.EnableAsync;
import org.springframework.scheduling.annotation.EnableScheduling;

@SpringBootApplication
@EnableScheduling // 启用定时任务
@EnableAsync //配置异步支持
@EnableAspectJAutoProxy(proxyTargetClass = true, exposeProxy = true) // exposeProxy = true
@MapperScan("com.huaxin.device.mapper")
@EnableCaching // 启用缓存
@EnableFeignClients(basePackages = "com.huaxin.feignclient") //启用FeignClient
@ComponentScan(basePackages = {
        "com.huaxin.device",
        "com.huaxin.hxredis",
        "com.hx.hxmybatisplus",
        "com.huaxin.hxswagger",
        "com.huaxin.hxjwt",
        "com.huaxin.feignclient",
        "com.huaxin.hxrabbitmq"})
public class HxDeviceApplication {
    public static void main(String[] args) {
        SpringApplication.run(HxDeviceApplication.class, args);
    }
}
